-
Notifications
You must be signed in to change notification settings - Fork 324
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Benchmark for C++ PDQ index #1699
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only some minor inline comments that I think will block extension. Otherwise looks good, thanks for doing it and for doing a README!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All my blocking comments resolved, let's shipit
for (int i = 0; i < numBitsToFlip; i++) { | ||
int bitIndex = bitIndices[i]; | ||
int wordIndex = bitIndex / 16; | ||
int position = bitIndex % 16; | ||
noisy.w[wordIndex] ^= (1 << position); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ignorable: This looks uniformly random to me!
Summary
Resolve #1697
C++ query benchmark program for brute force linear scan and mih (
pdq/cpp/index/mih.h
)Benchmark implementation located in
pdq/cpp/bin/benchmark-query.cpp
Benchmark results in
pdq/cpp/index/README.md
To run:
Sample results (ran on Ubuntu 24.04.1 LTS, Intel Core i7-14700KF with 20 cores, 28 threads, 64GB RAM):